import request from '@/util/request'

export function register(registerDto) {
  return request({
    url: '/user/register',
    method: 'post',
    data: registerDto
  })
}

export function login(loginDto) {
  return request({
    url: '/user/login',
    method: 'post',
    data: loginDto
  })
}

export function getUserInfo() {
  return request({
    url: '/user/info',
    method: 'get'
  })
}

export function logout() {
  return request({
    url: '/user/logout'
  })
}